<!DOCTYPE html>
<html lang="zh">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <script src="js/vue.js" type="text/javascript" charset="utf-8"></script>
    <title>event.stop</title>
</head>

<body>
    <div id="box">
        <div v-on:click="show('div的事件触发了')">
            <button v-on:click.stop="show('按钮的事件触发了')">显示</button>
        </div>
    </div>
    <script>
        new Vue({
            el: '#box',
            methods: {
                show: function(msg) {
                    alert(msg);
                }
            }
        })
    </script>
</body>

</html>